<!--edit page create by pionner at Wed Dec 17 19:00:54 CST 2008-->
<%@ taglib prefix="s" uri="/struts-tags" %>
<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
	<head>
	<base href="<%=basePath%>">
		<title>Bacterin</title>
	<meta http-equiv="pragma" content="no-cache">
	<meta http-equiv="cache-control" content="no-cache">
	<meta http-equiv="expires" content="0">
		<link rel="stylesheet" href="css/style.css">
		
		
	<script type="text/javascript">
	function IsEmpty()
{
var name=document.addform.name.value;
if(name==0){
alert("请填写完整内容！");
return;
}
document.addform.submit();
}
	
	
	
	function openTargetName(){
    		var title = ""; 
		var url = 'targetNameList.action';
		var pageUrl="targetNameList.action";
		var paraObj = new Object();
		paraObj.url=url;
		paraObj.title=title;
		var obj=document.getElementById('targetBacterinName');
		var targetBacterin=document.getElementById('targetBacterin');
		paraObj.input=obj;
		var sFeatures = 'help:no;status:1;dialogHeight:500px;dialogWidth:350px;center:1';
	    var rtnObj= window.showModalDialog(pageUrl,paraObj,sFeatures );
	    //alert('rtnObj='+rtnObj);
		if(rtnObj){
			var result=rtnObj.result;
			obj.value=result;
			targetBacterin.value=rtnObj.target;
		}else{
    		
    	}
    	}
	
	</script>
		
	</head>
	<body>
		<table width="200" border="0" cellspacing="0" cellpadding="0">
			<tr>
				<td width="90"><img src="images/loc-head.jpg" width="90" height="24"></td>
				<td valign="middle" class="title" nowrap background="images/loc-bg.jpg">新建</td>
				<td width="12"><img src="images/loc-tail.jpg" width="12" height="24"></td>
			</tr>
		</table><br>

		<table>
			<tr>
				<td background="1images/tb-bg.jpg" width="120">&nbsp;
					<a href="javascript:IsEmpty()" >
						<img src="images/btn-submit.jpg" border="0" style="cursor:hand;">
					</a>
				</td>
				<td background="1images/tb-bg.jpg" width="120">&nbsp;
					<a href="<s:url action="bacterinList"></s:url>" >
						<img src="images/btn-list.jpg" width="104" height="21" border="0" style="cursor:hand;">
					</a>
				</td>
			</tr>
		</table>

		<hr>
		<s:form name="addform"  action="bacterinSave.action">
			<table width='80%' border='0' cellspacing='1' class="ipttable">
				<s:textfield cssClass="input230" name='name' label='名称'/>
				
				<s:textfield cssClass="input230" name='offNum' label='距离开始时间'/>
				
				<tr><td><label class="label" >距离开始时间单位</label></td><td>
					<select name='offNumUnit' cssClass="input230">
						<option value="天" >天</option>
						<option value="周" >周</option>
<option value="月" >月</option>
<option value="年" >年</option>
					</select>
				</td></tr>
				<tr><td><label class="label" >疫苗类型</label></td><td>
					<select name='type' cssClass="input230">
						<option value="一" >一</option>
						<option value="二" >二</option>
					</select>
				</td></tr>
				<s:textfield cssClass="input230" name='targetBacterinName' label='参考上次时间' onclick="openTargetName()" onfocus="openTargetName()"/>
				
				<s:hidden name='targetBacterin' value="-1"/>
				<s:textfield cssClass="input230" name='price' label='价格'/>
			</table>
		</s:form>
	</body>
</html>
